STATEMENT:  return


return
 
The return statement specifies the value to be returned by a function and performs the act of returning that value to where the function was called from.
 
The following example returns the average of three numbers entered as arguments:
 
Code:
function average(a, b, c)
{
   return (a + b + c)/3;
}


Copyright 1999-2001 by Infinite Software Solutions, Inc. All rights reserved.
Trademark Information